/* ==============================================================================
*
*   Copyright (c) 2010, Pierre Favier
*   All rights reserved.
*
*   NTasking is free software: you can redistribute it and/or modify it
*   under the terms of the GNU General Public License as published by the
*   Free Software Foundation.
*
*   Redistribution and use in source and binary forms, with or without
*   modification, are permitted provided that the following conditions
*   are met:
*
*   -   Redistributions of source code must retain the above copyright notice,
*       this list of conditions and the following disclaimer.
*
*   -   Redistributions in binary form must reproduce the above
*       copyright notice, this list of conditions and the following
*       disclaimer in the documentation and/or other materials
*       provided with the distribution.
*
*   THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
*   WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
*   OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
*   DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
*   BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
*   EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
*   TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
*   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
*   ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
*   TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
*   THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
*   SUCH DAMAGE.
*
* ============================================================================== */

namespace NTasking.ValidationTests.ACATS_3_0.Support
{
    
    public static class Impdef
    {

        // This is the minimum time required to allow another task to get
        // control.  It is expected that the task is on the Ready queue.
        // A duration of 0.0 would normally be sufficient but some number
        // greater than that is expected.
        public const double MinimumTaskSwitch = 0.1;

        // This is the time required to activate another task and allow it
        // to run to its first accept statement.  We are considering a simple task
        // with very few Ada statements before the accept.  An implementation is
        // free to specify a delay of several seconds, or even minutes if need be.
        // The main effect of specifying a longer delay than necessary will be an
        // extension of the time needed to run the associated tests.
        public const double SwitchToNewTask = 1.0;

        // This is the time which will clear the queues of other tasks
        // waiting to run.  It is expected that this will be about five
        // times greater than Switch_To_New_Task.
        public const double ClearReadyQueue = 5.0;

        // Some implementations will boot with the time set to 1901/1/1/0.0
        // When a delay of Delay_For_Time_Past is given, the implementation
        // guarantees that a subsequent call to Ada.Calendar.Time_Of(1901,1,1)
        // will yield a time that has already passed (for example, when used in
        // a delay_until statement).
        public const double DelayForTimePast = 0.1;

        // Minimum time interval between calls to the time dependent Reset
        // procedures in Float_Random and Discrete_Random packages that is
        // guaranteed to initiate different sequences.  See RM A.5.2(45).
        public const double TimeDependentReset = 0.3;

        // Test CXA5013 will loop, trying to generate the required sequence
        // of random numbers.  If the RNG is faulty, the required sequence
        // will never be generated.  Delay_Per_Random_Test is a time-out value
        // which allows the test to run for a period of time after which the
        // test is failed if the required sequence has not been produced.
        // This value should be the time allowed for the test to run before it
        // times out.  It should be long enough to allow multiple (independent)
        // runs of the testing code, each generating up to 1000 random
        // numbers.
        public const double DelayPerRandomTest = 1.0;
    }

}
